import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import VueResource from 'vue-resource'

Vue.use(VueResource)
Vue.config.productionTip = false
//自定义指令开始
//彩虹标题博客标题随机变色
/* Vue.directive('rainbowTitle',{
	bind(el,binding,vnode){
		el.style.color= "#" + Math.random().toString(16).slice(2,8);
	}
}) */
//自定义过滤器
/* Vue.filter("to-uppercase",function (value) {
	return value.toUpperCase();
}) */
Vue.filter("snippet",function (value) {
	return value.slice(0,100) + "...";
})
//自定义指令结束

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
